package com.ys.modules.base.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;

@Data
@TableName("tg_user_assets_logs")
@ApiModel("资产流水记录")
public class TgUserAssetsLogs {
    @ApiModelProperty(value = "id")
    @TableId(type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "功能名称")
    private String name;

    @ApiModelProperty(value = "用户id")
    private Long userId;

    @ApiModelProperty(value = "资产类型: 1-USDT 2-USDN，根据资产表扩展")
    private Integer assetType;

    @ApiModelProperty(value = "资产变更数量，*10^6，正负分别表示增加和减少")
    private Long amount;

    @ApiModelProperty(value = "资产变更前数量，*10^6，便于回溯")
    private Long beforeAmount;

    @ApiModelProperty(value = "资产变更后数量，*10^6，便于回溯")
    private Long afterAmount;

    @ApiModelProperty(value = "流水关联交易id，比如充值，挖矿记录等，可用于去重")
    private String transactionId;

    @ApiModelProperty(value = "交易备注")
    private String remark;

    @ApiModelProperty(value = "数据版本号")
    private Long version;

    @ApiModelProperty(value = "关联记录id")
    private Long refId;

    @ApiModelProperty(value = "记录状态: 0-有效 1-无效")
    private Integer status;

    @ApiModelProperty(value = "创建者")
    private String creator;

    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @ApiModelProperty(value = "更新者")
    private String updater;

    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    @ApiModelProperty(value = "是否删除")
    private Integer deleted;
} 